<template>
  <div class="nav-box">
    <!-- 导航区 -->
    <el-card class="box-card box-card-top">
      <el-row>
        <el-breadcrumb separator="">
          <el-breadcrumb-item :to="{ path: '/' }">
            <el-button plain type="success" size="mini">后台主页<i class="el-icon-close el-icon--right" /></el-button>
          </el-breadcrumb-item>
          <!-- <el-breadcrumb-item :to="{ path:`/${this.$route.fullPath}` }">
            <el-button plain size="mini">上传<i class="el-icon-close el-icon--right" /></el-button>
          </el-breadcrumb-item> -->
        </el-breadcrumb>
      </el-row>
    </el-card></div>
</template>

<script>
export default {
  watch: {
    // # 通过监听$route的变化使用route.query.redirect获取查询参数，也就是退出页面时的地址
    $route: {
      handler: function(route) {
        this.redirect = route.query && route.query.redirect
      },
      immediate: true
    }
  }
}
</script>

<style lang="scss" scoped>
.nav-box {
  margin-bottom: 20px;

  ::v-deep .box-card .el-card__body {
    height: 30px;
    padding: 0 15px;

    .el-row {
      margin-top: 2px;

      .el-button {
        border-radius: 0;
      }
    }
  }
}
</style>
